package cn.kgc.springboot.mp.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.util.Date;

/**
 * @author 课工场
 * @date 2024/11/30
 * @description
 */
@Data
@TableName("user")
public class User {

    @TableId(type = IdType.AUTO)
    private Integer id;
    @TableField(value = "age",exist = true)
    private Integer age;
    private String password;
    private String username;
    private String sex;
    private String tel;

    // 标识该属性对应的字段是逻辑删除字段
    @TableLogic
    private Integer isDelete;

    @TableField(fill = FieldFill.INSERT)
    private Date createTime;
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;


    // 乐观锁字段
    @Version
    private Integer version;

}
